//
//  HWTakeTableViewCell.m
//  JWC
//
//  Created by lanou on 16/4/18.
//  Copyright © 2016年 陈帅. All rights reserved.
//

#import "HWTakeTableViewCell.h"
#import "UIImageView+WebCache.h"

@interface HWTakeTableViewCell ()

@property (weak, nonatomic) IBOutlet UIImageView *headImg;

@property (weak, nonatomic) IBOutlet UILabel *titleLabel;

@property (weak, nonatomic) IBOutlet UILabel *renCount;

@property (weak, nonatomic) IBOutlet UIButton *guanBtn;

@property (weak, nonatomic) IBOutlet UILabel *tieCount;

@end

@implementation HWTakeTableViewCell

- (void)setModel:(HWTakeModel *)model
{
    self.headImg.clipsToBounds = YES;
    [self.headImg sd_setImageWithURL:[NSURL URLWithString:model.image_list] placeholderImage:[UIImage imageNamed:@"20130411163304421951"]];
    self.titleLabel.text = model.theme_name;
    if (model.sub_number >= 10000 ) {
        self.renCount.text = [NSString stringWithFormat:@"%ld人订阅", model.sub_number / 10000];
    }
    else
    {
        self.renCount.text = [NSString stringWithFormat:@"%ld万人订阅", model.sub_number];
    }
    self.tieCount.text = [NSString stringWithFormat:@"总帖数:%ld", model.post_num];
}

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
